package org.example.common;

import com.alipay.api.AlipayClient;
import com.alipay.api.DefaultAlipayClient;

/**
 * @author 李国树
 * @version 1.0
 * @Desc
 * @date 2023/12/15 16:05
 */
public class AlipayConts {
    /**
     * 支付宝网关
     */
    public static final String ALIPAY_GATEWAY = "https://openapi-sandbox.dl.alipaydev.com/gateway.do";
    /**
     * APPID
     */
    public static final String ALIPAY_APPID = "2021000122675408";


    /**
     * 我的私钥
     */
    public static final String MY_PRIVATE_KEY = "MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCF1fZ6c6kS / wvJL + zMDW9OEUabxS//YkuCDFAY2sNmHldkaTLeQ/zTaoebQL92EMluAJPiG3iGLlOop+Xo1etowKclM78K9wn+592fvY4d9hGoMg2rnvib3VcLCcd5nFGmFLfCeMFQUc69kASy/3nDlFpxJgKnEf9anCUL0cAAklYO3lqY7KgtVn0BTApJyhoyNQokU0XqADSlYxejpqe9XjYygeewVcw738w6MION5ZwoeGSVAkuq71dc8kkEHooHnFMDknhpRuEu2tJK+AwIixOVRx4nWZnl5wq+PJnQ4Yx7xeD+Qe4lP5JXFV4bgOaT3DeKeIFUD1iSzRyEwF2BAgMBAAECggEAfLQN8rEcZAfjanXOVZ9bC8nLGc+VVoe3RZjFdTM5iEhTM8tVy4Zb6H5FlqKxA4jGt0mwgakJFzXJW8f90IKq07NWyrI5mzTuSmavuWz9I+upLihdVoFMsqZ9uVpGVIkUBwUc6AZuUbG4SicMSeEECvmLgAxjwlphrYL6fdXV6nET4vrX+914sLmpML9MZ3s/0KcNIwo6Q2Z1gKcdjdLYgr/nFLjenc4cdQHn0ljluanLu6Q6yEEgS3Vrg9IFhXeHJZoWpQToL7IzDC/MtYJfkiu57j8+b4tVBSzhD02+DikAUlVWFqeGiUzuD546Qdv1EKiEv7JpbWy2W62foI3ydQKBgQDTZPHnkb8j9vbvPRTA0tKmoaS9fqcfPXvQy70p60hH5GAd36lM8oC4ks3Ljc994mh3T0PLKmLIdkUre524uQIW2JWcvL0JlAml4LJN8mlJa+r7mzNO79kRK7YmVPxBNoxaJdvsTM7HIOri0m+aon9SN4lj/cl14RJttOey9pOO+wKBgQCiE3oyrq59I6Udv2sAggGalAbrjMtKNG5io15S82gPsYQ9Thiz3fimsvVVIBC/obkP6inNbYH78tW///pHH7q/M4gq9H7bm1ro4kvhCzOrqlMMSOdSk+m0/b7R7Cr7GnopclWpVU9ULCN0V5m8i/VdFl6ABaz9cHjWUragIAzsswKBgQDOl2iSFy3lyAWr6NXPXDnh/zcwugY50ayfcX186iPJnrcQevTJ7nU97LqSpBSTwiC1+REYDGRd5LfUtwp87NHN4fzVIN7d7X9ATUf0RWQADSeonRSXoG9TCJULASNF2DlyIG29kZLDqLfk1COdzBECGKR8xBmOyldoP9PwYmny4QKBgGRZ7vVmlv9AjMGofZYo6NlPAiHiYRSm9hn40TRHJY1h+mEC8+SacZS1hZWZbwVYGv+xmwRo42yeZJ6m3c4f5T7xp0QBcnKC9HzxcM38Y5fMs/MNSL0mfDPmULolok8ri6wR8NwRyDZzxdgJTVUiy19BtG1MFlotw4PgXtcyQQ5lAoGAQAEu/Ht7wDrcFlgY4WPDdXFX6cAPCGzpmgrToxD2nO50Ozpdh2JK6LOtU18S8xF5aUrmHwwT/4DzYhmkQ8WiOdvxtZm4D2UlP6ql26gwvfCRodghNW0rq+ttoOy+917PryBEsdFFzj5Qsw6RjXaRjQqoSw560Cs5UYL3U7H0gS8=";

    /**
     * 我的公钥
     */
    public static final String MY_PUBLIC_KEY = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAhdX2enOpEv8LyS/szA1vThFGm8Uv/2JLggxQGNrDZh5XZGky3kP802qHm0C/dhDJbgCT4ht4hi5TqKfl6NXraMCnJTO/CvcJ/ufdn72OHfYRqDINq574m91XCwnHeZxRphS3wnjBUFHOvZAEsv95w5RacSYCpxH/WpwlC9HAAJJWDt5amOyoLVZ9AUwKScoaMjUKJFNF6gA0pWMXo6anvV42MoHnsFXMO9/MOjCDjeWcKHhklQJLqu9XXPJJBB6KB5xTA5J4aUbhLtrSSvgMCIsTlUceJ1mZ5ecKvjyZ0OGMe8Xg/kHuJT+SVxVeG4Dmk9w3iniBVA9Yks0chMBdgQIDAQAB";
    /**
     * ;
     * 参数请求格式
     */
    public static final String FORMATE = "json";


    /**
     * 编码格式
     */
    public static final String CHARSET = "utf-8";

    /**
     * 支付宝公钥
     */
    public static final String ALIPAY_PUBLIC_KEY = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAr3sNsR/JE+Aww+EDVd/ob+yCpq5unaFsMj1n+uwynlnAyEP4hj/BTsUP0DqylF4R4nNozDL+qEmty1nOgYNJHIZQ5DQP/WJIhrjBAStn0FFijJ0zZjUj285lucSPTfEDtqVDvEergTtR3Zhvhe3R6ESVF0G8rGaHSI8z7C2942FNA/fb5eCd73/qZfVTh3xWYBdccmrbg/eSFJBr9ebvnrpAeasQcUXpwsIikKKSL/3/WmfXTGFxTQ/0kNHIsngg0plQQIEQqX35tSOubR3b+VaJiU/RHy5rvrpilLeJYwzTSmjHSWCaBNiND+SBS49Y8xUA8qCOrI7mmlfmUdmkhQIDAQAB";


    /**
     * 签名算法
     */
    public static final String SIGN_TYPE = "RSA2";

    /**
     * 同步回调地址
     */
    public static final String RETURN_URL = "http://localhost:8003/cloud-pay/pay/alipayCallback";

    /**
     * 异步回调地址
     */
    public static final String NOTIFY_URL = "http://p9wwtp.natappfree.cc/cloud-pay/pay/alipayCallback";


    /**
     * 接口调用公共封装
     */
    public static final AlipayClient ALIPAY_CLIENT = new DefaultAlipayClient(AlipayConts.ALIPAY_GATEWAY, AlipayConts.ALIPAY_APPID, AlipayConts.MY_PRIVATE_KEY, AlipayConts.FORMATE, AlipayConts.CHARSET, AlipayConts.ALIPAY_PUBLIC_KEY, AlipayConts.SIGN_TYPE);


    /**
     * 交易成功的状态
     */
    public static final String TRADE_SUCCESS = "TRADE_SUCCESS";
    /**
     * 交易关闭的状态
     */
    public static final String TRADE_CLOSED = "TRADE_CLOSED";

    /**
     * 支付宝未查询到订单
     */
    public static final String TRADE_NOT_EXIST = "ACQ.TRADE_NOT_EXIST";

}

 
